package com.zcl.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

import java.util.List;

//定义配置类
//加上注解声明该类为配置类
@Configuration   //包含有@Component注解,将该类构造成javabean放入spring容器中
//注解:全局配置中前缀为user的配置
@ConfigurationProperties(prefix = "user")
@Data
public class MyConfig {
    private int sid;
    private String sname;
    private int age;

}
